<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
    <th:block th:include="include :: header('顾客权益详情')" />
</head>
<body class="white-bg">
    <div class="wrapper wrapper-content animated fadeInRight ibox-content">
        <form class="form-horizontal m" id="form-equity-edit" th:object="${bizCustomerEquity}">
            <input name="id" th:field="*{id}" type="hidden">
            <div class="form-group">    
                <label class="col-sm-3 control-label">用户id：</label>
                <div class="col-sm-8">
                    <input name="customerId" th:field="*{customerId}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">手机号：</label>
                <div class="col-sm-8">
                    <input name="phone" th:field="*{phone}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">充电码：</label>
                <div class="col-sm-8">
                    <input name="code" th:field="*{code}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">设备号：</label>
                <div class="col-sm-8">
                    <input name="sn" th:field="*{sn}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">端口号：</label>
                <div class="col-sm-8">
                    <input name="cargo" th:field="*{cargo}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">权益数：</label>
                <div class="col-sm-8">
                    <input name="equity" th:field="*{equity}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">库存：</label>
                <div class="col-sm-8">
                    <input name="stock" th:field="*{stock}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">位置：</label>
                <div class="col-sm-8">
                    <input name="position" th:field="*{position}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">来源：</label>
                <div class="col-sm-8">
                    <input name="source" th:field="*{source}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">启用状态：</label>
                <div class="col-sm-8">
                    <div class="radio-box" th:each="dict : ${@dict.getType('enableStatus')}">
                        <input type="radio" th:id="${'status_' + dict.dictCode}" name="status" th:value="${dict.dictValue}" th:field="*{status}">
                        <label th:for="${'status_' + dict.dictCode}" th:text="${dict.dictLabel}"></label>
                    </div>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">备注：</label>
                <div class="col-sm-8">
                    <textarea name="remark" class="form-control">[[*{remark}]]</textarea>
                </div>
            </div>
        </form>
        <div class="form-control-static" style="text-align:center;">
            <button th:onclick="'javascript:closeItem()'" class="btn btn-danger" type="button">关闭</button>
        </div>
    </div>
    <th:block th:include="include :: footer" />
    <script th:inline="javascript">
        //使页面不可编辑
        function disableOcx() {
            var form = document.forms[0];
            for ( var i = 0; i < form.length; i++) {
                var element = form.elements[i];
                //部分元素可以编号 element.name 是元素自定义 name
                if (element.name != "auditEntity.auditContent"
                        && element.name != "auditEntity.auditAutograph"
                        && element.name != "auditEntity.auditTime"
                        && element.name != "auditEntity.auditState"
                        && element.name != "submitBtn"
                        && element.name != "reset"
                        && element.name != "id"
                        && element.name != "processInstanceId"
                        && element.name != "updateForm") {
                    element.disabled = "true";
                }
            }
        }
        window.onload = disableOcx;//当页面加载的时候执行此函数
        var prefix = ctx + "biz/equity";
    </script>
</body>
</html>